
/****************************** 
 * 
 *  Create By: Arthur.li
 *  
 *  Create At: 2009年4月24日 9:46:18
 *  
 *  Description: 手机号信息
 *  
 *  Remark: 
 *  
 * ****************************/


namespace Jumpton.SFA.Server.Entity {
    using System;
    using System.Collections.Generic;
    using System.Text;
    using Jumpton.Persistent;
    using System.Data;
    
    
    [Map("SIMInfo")]
    public class SIMInfo : ObjectRow {
        
        public SIMInfo() {
        }
        
        /// <summary>
        /// 构造函数
        /// </summary>
        /// <param name="dataRow">DataTable 中的一行数据</param>
        /// <param name="objectTable">存储当前对象的数据表格</param>
        public SIMInfo(System.Data.DataRow dataRow, ObjectTable parent) : 
                base(dataRow, parent) {
        }
        
        [Key("ID",true,true)]
        public decimal ID {
            get {
                return (System.Decimal)GetValue("ID");
            }
            set {
                SetValue("ID", value);
            }
        }
        
        [Field("IMSICode")]
        public string IMSICode {
            get {
                return (System.String)GetValue("IMSICode");
            }
            set {
                SetValue("IMSICode", value);
            }
        }
        
        [Field("PhoneNumber")]
        public string PhoneNumber {
            get {
                return (System.String)GetValue("PhoneNumber");
            }
            set {
                SetValue("PhoneNumber", value);
            }
        }
        
        [Field("IsActive")]
        public bool IsActive {
            get {
                return (System.Boolean)GetValue("IsActive");
            }
            set {
                SetValue("IsActive", value);
            }
        }
        
        [Field("UpdateBy")]
        public string UpdateBy {
            get {
                return (System.String)GetValue("UpdateBy");
            }
            set {
                SetValue("UpdateBy", value);
            }
        }
        
        [Field("LastUpdate")]
        public System.DateTime LastUpdate {
            get {
                if (GetValue("LastUpdate") == null)
                {
                    return DateTime.Now;
                }

                return (System.DateTime)GetValue("LastUpdate");
            }
            set {
                SetValue("LastUpdate", value);
            }
        }
    }
}
